﻿using System;
using System.Collections.Generic;
using System.Text;
using Castle.ActiveRecord;
using Castle.Components.Validator;
using Wolfut.MirageEE.Kernal.Common;

namespace Wolfut.MirageEE.Domain.Products
{
    /// <summary>
    /// 其他入库/出库信息
    /// </summary>
    /// <remarks>
    /// Author: LEO
    /// Date:2009-03-14
    /// </remarks>
    [ActiveRecord("IN_OUT_WAREHOUSE_ORDERS")]
    public class InOutWarehouseOrders : PersistentObjectWithGuid
    {
        #region 出入库类别号
        private string inOutWarehouseCategoryID = string.Empty;
        [Property("IN_OUT_WAREHOUSE_CATEGORY_ID")]
        [ValidateNonEmpty, ValidateLength(0, 40, "出入库类别号超长")]
        public virtual string InOutWarehouseCategoryID
        {
            get { return inOutWarehouseCategoryID; }
            set { inOutWarehouseCategoryID = value; }
        }
        #endregion

        #region 出入库编号
        private string inputOutputCode = string.Empty;
        [Property("INPUT_CODE")]
        [ValidateNonEmpty, ValidateLength(0, 100, "出入库编号超长")]
        public virtual string InputOutputCode
        {
            get { return inputOutputCode; }
            set { inputOutputCode = value; }
        }
        #endregion

        #region 日期
        private DateTime logDate = DateTime.Now;
        [Property("LOG_DATE")]
        public virtual DateTime LogDate
        {
            get { return logDate; }
            set { logDate = value; }
        }
        #endregion

        #region 生产任务单号
        private string productTaskBillCode = string.Empty;
        [Property("PRODUCE_TASK_CODE")]
        [ValidateNonEmpty, ValidateLength(0, 40, "生产任务单号超长")]
        public virtual string ProductTaskBillCode
        {
            get { return productTaskBillCode; }
            set { productTaskBillCode = value; }
        }
        #endregion

        #region 货物来源账号/货物存入账号
        private string sourceAccountID = string.Empty;
        [Property("SOURCE_ACCOUNT_ID")]
        [ValidateNonEmpty, ValidateLength(0, 100, "货物来源账号/货物存入账号超长")]
        public virtual string SourceAccountID
        {
            get { return sourceAccountID; }
            set { sourceAccountID = value; }
        }
        #endregion

        #region 供应商或客户
        private string supplierCustomer;
        [Property("SUPPLIER_CUSTOMER")]
        [ValidateNonEmpty, ValidateLength(0, 100, "供应商或客户超长")]
        public virtual string SupplierCustomer
        {
            get { return supplierCustomer; }
            set { supplierCustomer = value; }
        }
        #endregion

        #region 项目ID
        private string projectID = string.Empty;
        [Property("PROJECTS_ID")]
        [ValidateNonEmpty, ValidateLength(0, 40, "项目ID超长")]
        public virtual string ProjectID
        {
            get { return projectID; }
            set { projectID = value; }
        }
        #endregion

        #region 经办人
        private string handingPerson;
        [Property("HANDING_PERSONNEL")]
        [ValidateNonEmpty, ValidateLength(0, 100, "经办人内容超出长度")]
        public virtual string HandingPerson
        {
            get { return handingPerson; }
            set { handingPerson = value; }
        }
        #endregion

        #region 部门
        private string departmentCode = string.Empty;
        [Property("DEPT_CODE")]
        [ValidateNonEmpty, ValidateLength(0, 100, "部门超长")]
        public virtual string DepartmentCode
        {
            get { return departmentCode; }
            set { departmentCode = value; }
        }
        #endregion

        #region 备注
        private string remarks = string.Empty;
        [Property("REMARKS")]
        [ValidateLength(0, 2000, "备注超长")]
        public virtual string Remarks
        {
            get { return remarks; }
            set { remarks = value; }
        }
        #endregion

        #region 单位成本合计
        private decimal unitCostSum;
        [Property("UNIT_COST_SUM")]
        public virtual decimal UnitCostSum
        {
            get { return unitCostSum; }
            set { unitCostSum = value; }
        }
        #endregion

        #region 数量合计
        private decimal quantityTotal;
        [Property("NUMBER_SUM")]
        public virtual decimal QuantityTotal
        {
            get { return quantityTotal; }
            set { quantityTotal = value; }
        }
        #endregion

        #region 成本合计
        private decimal costSum;
        [Property("COST_SUM")]
        public virtual decimal CostSum
        {
            get { return costSum; }
            set { costSum = value; }
        }
        #endregion

        #region 是否删除
        private bool isDeleted;
        [Property("IS_DELETED")]
        public virtual bool IsDeleted
        {
            get { return isDeleted; }
            set { isDeleted = value; }
        }
        #endregion

    }
}
